package summer_vacation.liqiqi.day16;

/**
 * Created by uw on 2015/8/29.
 */
public class tuxing {
    public static void main(String[] args){
        int [][] a=new int [4][4];
        int n=1;
        int i;
        int j;
        for(i=0;i<4;i++) {
            for (j=0;j<4; j++) {
                    System.out.print(n+"\t");
                    n++;
                    if (j==3) {
                        System.out.println();
                        i++;
                        n++;
                        break;
                    }
            }
            j--;
            a[i][j]=n;
            System.out.println(a[i][j]);
            n++;
            if(n==8){
                for(i=2;i>=1;i--){
                    a[i][j]=n;
                    System.out.print(a[i][j]);
                    n++;
                    if(n==10){
                        break;
                    }
                }
            }
            }

        }
    }

